﻿<!-- Views/Admin/Index.cshtml -->
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
    ViewBag.Title = WebApplication1.Utilities.LanguageManager.GetText("AdminDashboard");
}

<div class="container">
    <h2>@WebApplication1.Utilities.LanguageManager.GetText("AdminDashboard")</h2>
    <hr />

    <div class="row">
        <div class="col-md-4">
            <div class="card text-white bg-primary mb-3">
                <div class="card-header">@WebApplication1.Utilities.LanguageManager.GetText("SystemStats")</div>
                <div class="card-body">
                    <h5 class="card-title">@ViewBag.Message</h5>
                    <p class="card-text">@WebApplication1.Utilities.LanguageManager.GetText("WelcomeMessageAdmin")</p>
                </div>
            </div>
        </div>

        <div class="col-md-4">
            <div class="card text-white bg-success mb-3">
                <div class="card-header">@WebApplication1.Utilities.LanguageManager.GetText("ExamManagement")</div>
                <div class="card-body">
                    <p class="card-text">
                        <a href="@Url.Action("Exams", "Admin")" class="btn btn-light btn-sm">
                            <span class="glyphicon glyphicon-list-alt"></span> @WebApplication1.Utilities.LanguageManager.GetText("ExamManagement")
                        </a>
                    </p>
                </div>
            </div>
        </div>

        <div class="col-md-4">
            <div class="card text-white bg-info mb-3">
                <div class="card-header">@WebApplication1.Utilities.LanguageManager.GetText("UserManagement")</div>
                <div class="card-body">
                    <p class="card-text">
                        <a href="@Url.Action("Users", "Admin")" class="btn btn-light btn-sm">
                            <span class="glyphicon glyphicon-user"></span> @WebApplication1.Utilities.LanguageManager.GetText("UserManagement")
                        </a>
                    </p>
                </div>
            </div>
        </div>
    </div>

    <div class="row">
        <div class="col-md-6">
            <div class="card">
                <div class="card-header">
                    <h5>@WebApplication1.Utilities.LanguageManager.GetText("QuickActions")</h5>
                </div>
                <div class="card-body">
                    <div class="btn-group-vertical w-100" role="group">
                        <a href="@Url.Action("Exams", "Admin")" class="btn btn-outline-primary mb-2">
                            <span class="glyphicon glyphicon-list-alt"></span> @WebApplication1.Utilities.LanguageManager.GetText("ManageExams")
                        </a>
                        <a href="@Url.Action("Users", "Admin")" class="btn btn-outline-success mb-2">
                            <span class="glyphicon glyphicon-user"></span> @WebApplication1.Utilities.LanguageManager.GetText("ManageUsers")
                        </a>
                        <a href="@Url.Action("ExamResults", "Admin")" class="btn btn-outline-warning">
                            <span class="glyphicon glyphicon-stats"></span> @WebApplication1.Utilities.LanguageManager.GetText("ViewResults")
                        </a>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-6">
            <div class="card">
                <div class="card-header">
                    <h5>@WebApplication1.Utilities.LanguageManager.GetText("RecentActivity")</h5>
                </div>
                <div class="card-body">
                    <ul class="list-group">
                        <li class="list-group-item">
                            <span class="glyphicon glyphicon-info-sign text-primary"></span>
                            @WebApplication1.Utilities.LanguageManager.GetText("SystemRunningNormal")
                        </li>
                        <li class="list-group-item">
                            <span class="glyphicon glyphicon-time text-info"></span>
                            @WebApplication1.Utilities.LanguageManager.GetText("CurrentTime")：@DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")
                        </li>
                        <li class="list-group-item">
                            <span class="glyphicon glyphicon-user text-success"></span>
                            @WebApplication1.Utilities.LanguageManager.GetText("WelcomeAdmin") @Session["Username"]
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>

    <div class="row mt-4">
        <div class="col-md-12">
            <div class="alert alert-info">
                <h4 class="alert-heading">@WebApplication1.Utilities.LanguageManager.GetText("UsageTips")</h4>
                <p>@WebApplication1.Utilities.LanguageManager.GetText("UsageTipsContent")</p>
                <hr>
                <p class="mb-0">@WebApplication1.Utilities.LanguageManager.GetText("ContactAdmin")</p>
            </div>
        </div>
    </div>
</div>